package com.listproject.di

import com.listproject.data.RepositoryImplOne
import com.listproject.data.RepositoryImplTwo
import com.listproject.repository.Repository
import dagger.Binds
import dagger.Module
import dagger.hilt.InstallIn
import dagger.hilt.components.SingletonComponent
import javax.inject.Named
import javax.inject.Singleton


@Module
@InstallIn(SingletonComponent::class)
abstract class RepositoryModule {

    @Binds
    @Singleton
    @Named("api1")
    abstract fun bindRepositoryOne(
        repositoryImplOne: RepositoryImplOne
    ): Repository


    @Binds
    @Singleton
    @Named("api2")
    abstract fun bindRepositoryTwo(
        repositoryImplTwo: RepositoryImplTwo
    ): Repository

}





















